package com.smforj.ssm.modules.lib.dao.impl;

import org.springframework.stereotype.Repository;
import org.springframework.util.Assert;

import com.smforj.ssm.frame.core.dao.impl.BaseDaoImpl;
import com.smforj.ssm.modules.lib.dao.EditingLogDao;
import com.smforj.ssm.modules.lib.domain.EditingLog;

@Repository
public class EditingLogDaoImpl extends BaseDaoImpl<EditingLog> implements
	EditingLogDao {

	@Override
	public long getEditingCount(String user) {  
		Assert.notNull(user); 
		Object obj= this.getSqlSessionTemplate().selectOne(getSqlName("getEditingCount"),user);
		System.out.println("obj: "+obj);
		return (long) obj;
	}

	@Override
	public long getEditingDate(String user) {
		Assert.notNull(user);
		return this.getSqlSessionTemplate().selectOne(getSqlName("getEditingDate"),user);
	}  

}
